
*** recode missing values
replace recpoolf=. if recpoolf==9999999 
replace totfelb=. if totfelb==9999999 
replace totrefb=. if totrefb==9999999 
replace totmisb=. if totmisb==9999999 
replace totadjb=. if totadjb==9999999 
replace totfadjb=. if totfadjb==9999999 
replace totmadjb=. if totmadjb==9999999 
replace agefroff=. if agefroff==9999999
replace refindex=. if refindex==9999999
replace jrefa=0 if jrefa==9999999
replace jfrefa=0 if jfrefa==9999999
replace wrstrefb=. if wrstrefb==9999999 
replace msprior=. if msprior==9999999 
replace mspriora=. if mspriora==9999999 




foreach x in jadja jfadja tarrfel jadjd jrefd jfrefa openadjd {
replace `x'=0 if `x'==9999999 
replace `x'=0 if `x'==. 
}



foreach x in adjindex jvfadjb jpfadjb jofadjb jmadjb jodadjb tarrest tarrfel tconvict tconvfel tprison tar_vop tcn_vop msoff1yr msadj1yr nxtadrsn nxtprg nxtin wrstrefd offen46d offenad minodte maxodte age{
replace `x'=. if `x'==9999999 
}


foreach x in  commita ccjuva jadjopen docpris docprob docfrst fdleprob fdlepris fdlearr fdlefarr fdleconv fdlefcon fdlefrst fdlettf tprison tprobat tcpbps adarrst fadarst adconv fadconv tarrest tarrfel tconvict tconvfel jref6 jfref6 jadj6 jfadj6 aciscon6 acisfcv6 frstoff6 commit6 ccjuv6 fdleprb6 fdleprs6 fdlearr6 fdlefar6 fdlecon6 fdlefrs6 docfrst6 adarrst6 fadarst6 adconv6 fadconv6 tarrest6 tarrfel6 tconvic6 tconvfl6 badjvf badjpf badjof badjm badjod ageencat agerel  provider ID_VAR RELEASE_YR FILE_TYPE jrefav jadjav commitav ccjuvav tarrfel_both tconvfel_both tar_vop tcn_vop tcm_vop tprb_vop tprs_vop tcp_vop CAR_CPACT{
replace `x'=. if `x'==9999999
}

replace commitav=0 if commitav==.

